package com.qinggeng.project.system.service.impl;

import com.qinggeng.project.system.domain.AppConfig;
import com.qinggeng.project.system.mapper.AppConfigMapper;
import com.qinggeng.project.system.service.AppConfigService;
import org.springframework.beans.factory.annotation.Autowired;
import org.springframework.stereotype.Service;
import org.springframework.transaction.annotation.Transactional;

import java.util.List;

/**
* @author Gaoao
* @date 2020-02-11
*/
@Service
public class AppConfigServiceImpl implements AppConfigService {

    @Autowired
    private AppConfigMapper appConfigMapper;


    @Override
    public List<AppConfig> queryAppConfigList(AppConfig appConfig) {
        return appConfigMapper.selectAppConfigList(appConfig);
    }

    @Override
    public AppConfig findAppConfigById(Integer id) {
        return appConfigMapper.selectAppConfigById(id);
    }

    @Override
    @Transactional
    public int createAppConfig(AppConfig appConfig) {
        return appConfigMapper.insertAppConfig(appConfig);
    }

    @Override
    @Transactional
    public int updateAppConfig(AppConfig appConfig) {
        return appConfigMapper.updateAppConfig(appConfig);
    }

    @Override
    @Transactional
    public int deleteAppConfigById(Integer id) {
        return appConfigMapper.deleteAppConfigById(id);
    }



}
